mean Function

public function mean(a) result(mn)

Function to calculate the mean of a real array

Arguments

Type IntentOptional Attributes Name
real(kind=wp), intent(inout), dimension(:) :: a

A real array

Return Value real(kind=wp)

A real value with the calculated mean


Calls

proc~~mean~~CallsGraph proc~mean mean float float proc~mean->float

Called by

proc~~mean~~CalledByGraph proc~mean mean proc~coefficient_of_variation coefficient_of_variation proc~coefficient_of_variation->proc~mean proc~std std proc~coefficient_of_variation->proc~std proc~correlation_coefficient correlation_coefficient proc~correlation_coefficient->proc~mean proc~correlation_coefficient->proc~std proc~variance variance proc~variance->proc~mean proc~std->proc~variance

Source Code

    function mean(a) result(mn)
!=============================================================================================
!! Function to calculate the mean of a real array
        real(kind=wp),dimension(:),intent(inout) :: a
!! A real array
        real(kind=wp) :: mn
!! A real value with the calculated mean
        mn=sum(a)/float(size(a));
!
    end function mean